@extends('frontend/layouts/bootstrap')

@section('content')
<h2>{{ $purchase_car->chasis_no }}-d penalty nemeh</h2>

{{ Form::open(array('route' => array('car_balance.car.create_penalty', $purchase_car->id), 'class' => 'form-horizontal')) }}

<h4>Penalty detial</h4>
<table class="table table-bordered" id="billDetailed">
    <thead style="background-color: #f0f0f0;">
    <th title="Customer">Customer</th>
    <th title="Date">日付</th>
    <th title="Auction">オーク会場</th>
    <th title="Auction no">出品番号</th>
    <th title="Car name">車種</th>
    <th title="Car year">年式</th>
    <th title="Chassis number">車体番号</th>
    <th title="Penalty date">Penalty date</th>
    <th style="text-align: center;" title="Penalty amount">Penalty amount</th>
    <th title="Penalty type">Penalty type</th>
    </thead>
    <tr>
        <td>{{ $purchase_car->customer->name }}</td>
        <td>{{ $purchase_car->purchase_date }}</td>
        <td>{{ $purchase_car->auction_name }}</td>
        <td>{{ $purchase_car->lot_no }}</td>
        <td>{{ $purchase_car->car_maker }} {{ $purchase_car->car_name }}</td>
        <td>{{ $purchase_car->car_year }}</td>
        <td>{{ $purchase_car->chasis_no }}</td>
        <td{{ $errors->first('penalty_date', ' class="control-group error"') }}>
        <input class="datepicker input-medium" placeholder="Penalty Date" title="Penalty Date" name="penalty_date" type="text">
        {{ $errors->first('penalty_date', '<span class="help-inline">:message</span>') }}
        </td>
        <td{{ $errors->first('penalty_amount', ' class="control-group error"') }}>
            <input class="input-small" placeholder="Penalty amount" title="Penalty amount" name="penalty_amount" type="text" id="penalty_amount">
            {{ $errors->first('penalty_amount', '<span class="help-inline">:message</span>') }}
        </td>
        <td{{ $errors->first('penalty_type', ' class="control-group error"') }}>
        <input style="margin: 0;" type="radio" name="penalty_type" value="1" class="radio" id="penalty_type1" checked="checked">Tulbur udaasan
        <input style="margin: 0;" type="radio" name="penalty_type" value="2" class="radio" id="penalty_type2">Auction
        </td>
    </tr>
</table>

<button type="submit" class="btn btn-large btn-success"><i class="icon-plus icon-white"></i> Хадгалах</button> &nbsp;&nbsp;

{{  Form::close() }}

@stop


@section('pagestyles')
<link rel="stylesheet" type="text/css" href={{ asset('assets/chosen-bootstrap/chosen.min.css') }} />
<link rel="stylesheet" type="text/css" href={{ asset('assets/bootstrap-daterangepicker/daterangepicker.css') }} />
<link rel="stylesheet" type="text/css" href={{ asset('assets/lightbox/lightbox.css') }} />
<link rel="stylesheet" type="text/css" href={{ asset('assets/bootstrap-datepicker/datepicker.css') }} />
<style type="text/css" media="screen">
</style>
@stop

@section('pagescripts')
<!--page specific plugin scripts-->
<script type="text/javascript" src={{ asset('assets/chosen-bootstrap/chosen.jquery.min.js') }}></script>
<script type="text/javascript" src={{ asset('assets/bootstrap-daterangepicker/date.js') }} ></script>
<script type="text/javascript" src={{ asset('assets/bootstrap-daterangepicker/daterangepicker.js') }}></script>
<script type="text/javascript" src={{ asset('assets/lightbox/lightbox-2.6.min.js') }}></script>
<script type="text/javascript" src={{ asset('assets/bootstrap-datepicker/datepicker.js') }}></script>
<script type="text/javascript">
    $(function() {
        $( ".datepicker" ).datepicker({
            defaultDate: "+0d",
            format: "yyyy-mm-dd",
            autoclose: true
        });
    });

</script>
@stop